package com.bosch.in.rtp1.ept.model.technical;

import java.util.ArrayList;
import java.util.List;

/**
 * Class encapsulates all search parameters, dynamic sql statement or search condition.
 * @author LIV1HC
 *
 */

public class Condition4FxFactor {
	/**
	 * Normal conditions
	 */
	private int year;
	private int priority;
	private int prodArea;
	private boolean loadPreviousYear;
	/**
	 * Parameter values, the number of values must be equal with 
	 * the number of place holder in search condition
	 */
	private List<Object> parameterValues;
	
	public Condition4FxFactor() {	
		this.loadPreviousYear = false;
		this.priority = -1;
		this.prodArea = -1;
	}
	
	public int getYear() {
		return year;
	}
	
	public boolean isLoadPreviousYear() {
		return loadPreviousYear;
	}

	public void setLoadPreviousYear(boolean loadPreviousYear) {
		this.loadPreviousYear = loadPreviousYear;
	}

	public void setYear(int year) {
		this.year = year;
	}
	
	public int getPriority() {
		return priority;
	}
	
	public void setPriority(int priority) {
		this.priority = priority;
	}
	
	public int getProdArea() {
		return prodArea;
	}
	
	public void setProdArea(int prodArea) {
		this.prodArea = prodArea;
	}

	public void setParameterValues(List<Object> parameterValues) {
		this.parameterValues = parameterValues;
	}

	public List<Object> getParameterValues() {
		return parameterValues;
	}
	
	public void builParameterValuesList()
	{
		this.parameterValues = new ArrayList<Object>();
		this.parameterValues.add(this.year);
		this.parameterValues.add(this.priority);
		this.parameterValues.add(this.prodArea);
	}
}
